home *** CD-ROM | disk | FTP | other *** search
- unit Unit2;
-
- interface
-
- uses
- SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls,
- Forms, Dialogs, StdCtrls, DimLib;
-
- type
- TForm2 = class(TForm)
- Button1: TButton;
- Button2: TButton;
- Label1: TLabel;
- procedure Button1Click(Sender: TObject);
- procedure Button2Click(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
-
- var
- Form2: TForm2;
-
- implementation
-
- {$R *.DFM}
-
- procedure TForm2.Button1Click(Sender: TObject);
- begin
- DimWindow(Handle);
- MessageDlg('Thanks!', mtInformation, [mbOk], 0);
- UnDimWindow(Handle);
- ModalResult := mrYes;
- end;
-
- procedure TForm2.Button2Click(Sender: TObject);
- begin
- DimWindow(Handle);
- MessageDlg('Bummer!', mtInformation, [mbOk], 0);
- UnDimWindow(Handle);
- ModalResult := mrNo;
- end;
-
- end.
-